<template>
	<scroll-view class="content" scroll-y>
		<block>
			<view class="container">

				<view class="flex-row">
					<view class="flex-row1">

						<view class="title">
							<view>{{datas.notice_title}}</view>
						</view>
					</view>
					<!-- <view class="read"></view> -->
				</view>
				<view class="flex-row flex-row2">
					<view class="read">发布时间:{{datas.crate_time}}</view>
					<view class="read2">阅读:{{datas.browse_num}}</view>
				</view>
				<view class="flex-row3">
					<rich-text :nodes="detail"></rich-text>
				</view>

			</view>
		</block>
	</scroll-view>
</template>

<script>
	export default {
		data() {
			return {
				mockList: [],
				datas: '',
				detail:''
			};
		},
		onLoad: function(e) {
			this.datas = JSON.parse(decodeURIComponent(e.data).replace(/&lt;/g,'<').replace(/&gt;/g,'>'));
			this.detail = this.datas.notice_text.replace(/&quot;/g,'"');
			this.detail = this.detail.replace(/src="http/g,'style="max-width:100%;" src="http');
			this.groupid = uni.getStorageSync('groupData').groupid;
			var token = uni.getStorageSync('token');
			this.$gapi.apiPost('user/app/browseNum', {
				"k_token": token,
				"notice_id": this.datas.notice_id
			}).then(res => {
				console.log(res.data);
			});
		}
	}
</script>

<style>
	.title {
		display: flex;
		justify-content: flex-start;
		width: 95%;
		font-size: 32upx !important;
		
	}

	.title view {
		text-indent: 20upx;
		font-size: 36upx;
	}

	.title:before {
		content: '|';
		width: 4upx;
		height: 30upx;
		color: #00adff;
		margin-top: -5upx;


	}

	.content {
		position: absolute;
		height: 100%;
		width: 100%;
		background-color: #FFFFFF;
	}

	.container {
		background-color: #ffffff;
		padding-top: 9upx;
		/* margin-bottom: 20upx; */
	}

	.blue-line {
		width: 4upx;
		height: 40upx;
		background: #00adff;
		margin-top: 10upx;
		margin-right: 10upx;
	}

	.flex-row {
		display: flex;
		flex-direction: row;
		align-items: center;
	}

	.flex-row1 {
		width: 100%;
		min-height: 40upx;
		display: flex;
		flex-direction: row;
		align-items: center;
		margin-left: 20upx;
		margin-top: 10upx;
		font-size: 32upx;
		color: #333333;
	}

	.grid_r1_l1_top:after {
		content: "【置顶】";
		display: inline-block;
		font-size: 26upx;
		color: #f10000;
	}

	.read {
		font-size: 30upx;
		color: #999999;
	}

	.read2 {
		font-size: 30upx;
		color: #999999;
		margin-right: 30upx;
	}

	.flex-row2 {
		width: 710upx;
		height: 62upx;
		margin: 0 auto;
		display: flex;
		flex-direction: row;
		align-items: center;
		justify-content: space-between;
		padding-left: 20upx;
		color: #999999;
		border-bottom: 1px solid #e5e5e5;
	}

	.flex-row3 {
		width: 90%;
		height: auto;
		display: flex;
		flex-direction: row;
		align-items: center;
		margin: auto;
		font-size: 28upx;
		color: #666666;
		margin-top: 30upx;
	}
	
	rich-text{
		width: 100%;
		font-size: 34upx;
	}
</style>
